package com.example.smarthomeservers.utils;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 * @author zdl
 * date 2018/7/19 0019 20:19
 * email zdl328465042@163.com
 * description 全局工具类
 */
public class GlobalUtil {

    private static Logger logger;

    /**
     * 实例logger
     * @param cls class
     * @return logger
     */
    public static Logger loggerInfo(Class cls){
        if (null == logger){
            logger = LoggerFactory.getLogger(cls);
        }
        return logger;
    }
}
